package com.kingdee.pda.util;

import android.content.Context;
import android.os.Build;

/**
 * Created by zhanlg
 * DATE 2017/10/26
 * TIME 11:49
 */

public class ColorUtils {


    public static int getColor(Context context, int id) {
        if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.M) {
            return context.getResources().getColor(id, context.getTheme());
        } else {
            return context.getResources().getColor(id);
        }
    }
}
